package com.wxq.blog.vo;

import lombok.AllArgsConstructor;
import lombok.Data;

@Data
@AllArgsConstructor
public class Result {
   private boolean success;
   private int code;
   private String msg;
   private Object data;

    public static Result success(Object obj){
        return new Result(true,200,"获取成功",obj);
    }
    public static Result fail(int code, String msg){
        return new Result(false,code,msg,null);
    }
}
